package com.smart.gui;

import java.awt.Font;

import javax.swing.JButton;
import javax.swing.JComboBox;
import javax.swing.JFrame;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JScrollPane;
import javax.swing.JTextArea;
import javax.swing.border.EmptyBorder;

import com.jgoodies.forms.factories.FormFactory;
import com.jgoodies.forms.layout.ColumnSpec;
import com.jgoodies.forms.layout.FormLayout;
import com.jgoodies.forms.layout.RowSpec;
import com.smart.core.AppManager.DesiredEnum;


public class Legacy_and_Target_Test_Environment_Part2 extends JFrame {

	/**
	 * 
	 */
	private static final long serialVersionUID = 2120097261950839898L;

	private JPanel contentPane;

	/**
	 * singleton pattern -- getInstance
	 */
	private static Legacy_and_Target_Test_Environment_Part2 uniqueInstanceForm;

	public static synchronized Legacy_and_Target_Test_Environment_Part2 getInstance() {
		if (uniqueInstanceForm == null) {
			try {
				uniqueInstanceForm = new Legacy_and_Target_Test_Environment_Part2();
			} catch (Exception e) {
				e.printStackTrace();
			}
		}
		return uniqueInstanceForm;
	}

	/**
	 * Create the frame.
	 */
	public Legacy_and_Target_Test_Environment_Part2() {
		ButtonHandler handler = new ButtonHandler(this);

		setTitle("Legacy and Target Test Environment Questionnaire -- Part 2");
		setDefaultCloseOperation(JFrame.HIDE_ON_CLOSE);
		setBounds(25, 25, 1124, 497);
		contentPane = new JPanel();
		contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
		setContentPane(contentPane);
		contentPane.setLayout(new FormLayout(
				new ColumnSpec[] {
						FormFactory.RELATED_GAP_COLSPEC, 
						FormFactory.MIN_COLSPEC,
						FormFactory.RELATED_GAP_COLSPEC,
						ColumnSpec.decode("default:grow"),
						FormFactory.RELATED_GAP_COLSPEC, 
						FormFactory.MIN_COLSPEC, 
						FormFactory.RELATED_GAP_COLSPEC, 
						FormFactory.MIN_COLSPEC,
						FormFactory.RELATED_GAP_COLSPEC,
						ColumnSpec.decode("default:grow"),
						FormFactory.RELATED_GAP_COLSPEC, 
						FormFactory.MIN_COLSPEC, 
						FormFactory.RELATED_GAP_COLSPEC, },
				new RowSpec[] { 
				        FormFactory.RELATED_GAP_ROWSPEC,
						FormFactory.MIN_ROWSPEC,
						FormFactory.RELATED_GAP_ROWSPEC,
						FormFactory.MIN_ROWSPEC,
						FormFactory.RELATED_GAP_ROWSPEC,
						RowSpec.decode("default:grow"),
						FormFactory.RELATED_GAP_ROWSPEC,
						FormFactory.MIN_ROWSPEC,
						FormFactory.RELATED_GAP_ROWSPEC,
						RowSpec.decode("default:grow"),
						FormFactory.RELATED_GAP_ROWSPEC,
						FormFactory.MIN_ROWSPEC,
						FormFactory.RELATED_GAP_ROWSPEC,
						RowSpec.decode("default:grow"),
						FormFactory.RELATED_GAP_ROWSPEC,
						FormFactory.MIN_ROWSPEC,
						FormFactory.RELATED_GAP_ROWSPEC,
						RowSpec.decode("default:grow"),
						FormFactory.RELATED_GAP_ROWSPEC,
						FormFactory.MIN_ROWSPEC,
						FormFactory.RELATED_GAP_ROWSPEC,
						RowSpec.decode("default:grow"),
						FormFactory.RELATED_GAP_ROWSPEC,
						FormFactory.MIN_ROWSPEC,
						FormFactory.RELATED_GAP_ROWSPEC,
						RowSpec.decode("default:grow"),
						FormFactory.RELATED_GAP_ROWSPEC,
						FormFactory.MIN_ROWSPEC,
						FormFactory.RELATED_GAP_ROWSPEC,
						RowSpec.decode("default:grow"),
						FormFactory.RELATED_GAP_ROWSPEC,
						FormFactory.MIN_ROWSPEC, }));

		JLabel lblCandidateTestCases = new JLabel(
				"Candidate Test Cases for Migration");
		contentPane.add(lblCandidateTestCases, "4, 2");

		JLabel lblDesirable = new JLabel("Desirable?");
		contentPane.add(lblDesirable, "6, 2");

		JLabel lblDesirable2 = new JLabel("Desirable?");
		contentPane.add(lblDesirable2, "12, 2");

		JLabel label = new JLabel("1)");
		contentPane.add(label, "2, 4");

		JLabel lblHavePotentialTest = new JLabel(
				"Have potential test cases for migration been identitfied?");
		contentPane.add(lblHavePotentialTest, "4, 4, left, default");

		JComboBox<DesiredEnum> comboBox = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox.setName("comboBox");
		comboBox.setMaximumRowCount(DesiredEnum.values().length);
		comboBox.setEditable(false);
		comboBox.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox, "6, 4, fill, default");

		JScrollPane scrollPane = new JScrollPane();
		contentPane.add(scrollPane, "4, 6, 3, 1, fill, fill");

		JTextArea textArea = new JTextArea();
		textArea.setName("textArea");
		textArea.setWrapStyleWord(true);
		textArea.setLineWrap(true);
		textArea.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea.setRows(1);
		scrollPane.setViewportView(textArea);

		JLabel label_1 = new JLabel("2)");
		contentPane.add(label_1, "2, 8");

		JLabel lblWhatWasThe = new JLabel(
				"What was the process to identify these test cases?");
		contentPane.add(lblWhatWasThe, "4, 8, left, default");

		JComboBox<DesiredEnum> comboBox_1 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_1.setName("comboBox_1");
		comboBox_1.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_1.setEditable(false);
		comboBox_1.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_1, "6, 8, fill, default");

		JScrollPane scrollPane_1 = new JScrollPane();
		contentPane.add(scrollPane_1, "4, 10, 3, 1, fill, fill");

		JTextArea textArea_1 = new JTextArea();
		textArea_1.setName("textArea_1");
		textArea_1.setWrapStyleWord(true);
		textArea_1.setLineWrap(true);
		textArea_1.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_1.setRows(1);
		scrollPane_1.setViewportView(textArea_1);

		JLabel label_2 = new JLabel("3)");
		contentPane.add(label_2, "2, 12");

		JLabel lblWhatApplicationsWill = new JLabel(
				"What applications will be using these tests?");
		contentPane.add(lblWhatApplicationsWill, "4, 12, left, default");

		JComboBox<DesiredEnum> comboBox_2 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_2.setName("comboBox_2");
		comboBox_2.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_2.setEditable(false);
		comboBox_2.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_2, "6, 12, fill, default");

		JScrollPane scrollPane_2 = new JScrollPane();
		contentPane.add(scrollPane_2, "4, 14, 3, 1, fill, fill");

		JTextArea textArea_2 = new JTextArea();
		textArea_2.setName("textArea_2");
		textArea_2.setWrapStyleWord(true);
		textArea_2.setLineWrap(true);
		textArea_2.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_2.setRows(1);
		scrollPane_2.setViewportView(textArea_2);

		JLabel label_3 = new JLabel("4)");
		contentPane.add(label_3, "2, 16");

		JLabel lblHowDoThese = new JLabel(
				"How do these selected tests/tes suites represent the goals of migration?");
		contentPane.add(lblHowDoThese, "4, 16, left, default");

		JComboBox<DesiredEnum> comboBox_3 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_3.setName("comboBox_3");
		comboBox_3.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_3.setEditable(false);
		comboBox_3.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_3, "6, 16, fill, default");

		JScrollPane scrollPane_3 = new JScrollPane();
		contentPane.add(scrollPane_3, "4, 18, 3, 1, fill, fill");

		JTextArea textArea_3 = new JTextArea();
		textArea_3.setName("textArea_3");
		textArea_3.setWrapStyleWord(true);
		textArea_3.setLineWrap(true);
		textArea_3.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_3.setRows(1);
		scrollPane_3.setViewportView(textArea_3);

		JLabel label_4 = new JLabel("5)");
		contentPane.add(label_4, "2, 20");

		JLabel lblWhatTypesOf = new JLabel(
				"What types of test are currently in use in the system?");
		contentPane.add(lblWhatTypesOf, "4, 20, left, default");

		JComboBox<DesiredEnum> comboBox_4 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_4.setName("comboBox_4");
		comboBox_4.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_4.setEditable(false);
		comboBox_4.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_4, "6, 20, fill, default");

		JScrollPane scrollPane_4 = new JScrollPane();
		contentPane.add(scrollPane_4, "4, 22, 3, 1, fill, fill");

		JTextArea textArea_4 = new JTextArea();
		textArea_4.setName("textArea_4");
		textArea_4.setWrapStyleWord(true);
		textArea_4.setLineWrap(true);
		textArea_4.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_4.setRows(1);
		scrollPane_4.setViewportView(textArea_4);

		JLabel label_5 = new JLabel("6)");
		contentPane.add(label_5, "2, 24");

		JLabel lblWhatTypesOf_1 = new JLabel(
				"What types of tests are expected to be migrated?");
		contentPane.add(lblWhatTypesOf_1, "4, 24, left, default");

		JComboBox<DesiredEnum> comboBox_5 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_5.setName("comboBox_5");
		comboBox_5.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_5.setEditable(false);
		comboBox_5.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_5, "6, 24, fill, default");

		JScrollPane scrollPane_5 = new JScrollPane();
		contentPane.add(scrollPane_5, "4, 26, 3, 1, fill, fill");

		JTextArea textArea_5 = new JTextArea();
		textArea_5.setName("textArea_5");
		textArea_5.setWrapStyleWord(true);
		textArea_5.setLineWrap(true);
		textArea_5.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_5.setRows(1);
		scrollPane_5.setViewportView(textArea_5);

		JLabel label_6 = new JLabel("7)");
		contentPane.add(label_6, "2, 28");

		JLabel lblWhatProgrammingLanguagess = new JLabel(
				"What programming languages(s) is(are) the tests written in?");
		contentPane.add(lblWhatProgrammingLanguagess, "4, 28, left, default");

		JComboBox<DesiredEnum> comboBox_6 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_6.setName("comboBox_6");
		comboBox_6.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_6.setEditable(false);
		comboBox_6.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_6, "6, 28, fill, default");

		JScrollPane scrollPane_6 = new JScrollPane();
		contentPane.add(scrollPane_6, "4, 30, 3, 1, fill, fill");

		JTextArea textArea_6 = new JTextArea();
		textArea_6.setName("textArea_6");
		textArea_6.setWrapStyleWord(true);
		textArea_6.setLineWrap(true);
		textArea_6.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_6.setRows(1);
		scrollPane_6.setViewportView(textArea_6);

		JLabel label_7 = new JLabel("8)");
		contentPane.add(label_7, "8, 4");

		JLabel lblWhatDependenciesExist = new JLabel(
				"What dependencies exist between the tests/test suites?");
		contentPane.add(lblWhatDependenciesExist, "10, 4, left, default");

		JComboBox<DesiredEnum> comboBox_7 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_7.setName("comboBox_7");
		comboBox_7.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_7.setEditable(false);
		comboBox_7.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_7, "12, 4, fill, default");

		JScrollPane scrollPane_7 = new JScrollPane();
		contentPane.add(scrollPane_7, "10, 6, 3, 1, fill, fill");

		JTextArea textArea_7 = new JTextArea();
		textArea_7.setName("textArea_7");
		textArea_7.setWrapStyleWord(true);
		textArea_7.setLineWrap(true);
		textArea_7.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_7.setRows(1);
		scrollPane_7.setViewportView(textArea_7);

		JLabel label_8 = new JLabel("9)");
		contentPane.add(label_8, "8, 8");

		JLabel lblAreDependeciesEasy = new JLabel(
				"Are dependencies easy to identify?");
		contentPane.add(lblAreDependeciesEasy, "10, 8, left, default");

		JComboBox<DesiredEnum> comboBox_8 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_8.setName("comboBox_8");
		comboBox_8.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_8.setEditable(false);
		comboBox_8.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_8, "12, 8, fill, default");

		JScrollPane scrollPane_8 = new JScrollPane();
		contentPane.add(scrollPane_8, "10, 10, 3, 1, fill, fill");

		JTextArea textArea_8 = new JTextArea();
		textArea_8.setName("textArea_8");
		textArea_8.setWrapStyleWord(true);
		textArea_8.setLineWrap(true);
		textArea_8.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_8.setRows(1);
		scrollPane_8.setViewportView(textArea_8);

		JLabel label_9 = new JLabel("10)");
		contentPane.add(label_9, "8, 12");

		JLabel lblAreTheTests = new JLabel(
				"Are the tests readable and easy to understand?");
		contentPane.add(lblAreTheTests, "10, 12, left, default");

		JComboBox<DesiredEnum> comboBox_9 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_9.setName("comboBox_9");
		comboBox_9.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_9.setEditable(false);
		comboBox_9.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_9, "12, 12, fill, default");

		JScrollPane scrollPane_9 = new JScrollPane();
		contentPane.add(scrollPane_9, "10, 14, 3, 1, fill, fill");

		JTextArea textArea_9 = new JTextArea();
		textArea_9.setName("textArea_9");
		textArea_9.setWrapStyleWord(true);
		textArea_9.setLineWrap(true);
		textArea_9.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_9.setRows(1);
		scrollPane_9.setViewportView(textArea_9);

		JLabel label_10 = new JLabel("11)");
		contentPane.add(label_10, "8, 16");

		JLabel lblAreTheTests_1 = new JLabel("Are the tests documented?");
		contentPane.add(lblAreTheTests_1, "10, 16, left, default");

		JComboBox<DesiredEnum> comboBox_10 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_10.setName("comboBox_10");
		comboBox_10.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_10.setEditable(false);
		comboBox_10.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_10, "12, 16, fill, default");

		JScrollPane scrollPane_10 = new JScrollPane();
		contentPane.add(scrollPane_10, "10, 18, 3, 1, fill, fill");

		JTextArea textArea_10 = new JTextArea();
		textArea_10.setName("textArea_10");
		textArea_10.setWrapStyleWord(true);
		textArea_10.setLineWrap(true);
		textArea_10.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_10.setRows(1);
		scrollPane_10.setViewportView(textArea_10);

		JLabel label_11 = new JLabel("12)");
		contentPane.add(label_11, "8, 20");

		JLabel lblAreTheTest = new JLabel(
				"Are the test results clear and easy to understand?");
		contentPane.add(lblAreTheTest, "10, 20, left, default");

		JComboBox<DesiredEnum> comboBox_11 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_11.setName("comboBox_11");
		comboBox_11.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_11.setEditable(false);
		comboBox_11.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_11, "12, 20, fill, default");

		JScrollPane scrollPane_11 = new JScrollPane();
		contentPane.add(scrollPane_11, "10, 22, 3, 1, fill, fill");

		JTextArea textArea_11 = new JTextArea();
		textArea_11.setName("textArea_11");
		textArea_11.setWrapStyleWord(true);
		textArea_11.setLineWrap(true);
		textArea_11.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_11.setRows(1);
		scrollPane_11.setViewportView(textArea_11);

		JLabel label_12 = new JLabel("13)");
		contentPane.add(label_12, "8, 24");

		JLabel lblHowDifficultIs = new JLabel(
				"How difficult is test maintenance in the current system?");
		contentPane.add(lblHowDifficultIs, "10, 24, left, default");

		JComboBox<DesiredEnum> comboBox_12 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_12.setName("comboBox_12");
		comboBox_12.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_12.setEditable(false);
		comboBox_12.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_12, "12, 24, fill, default");

		JScrollPane scrollPane_12 = new JScrollPane();
		contentPane.add(scrollPane_12, "10, 26, 3, 1, fill, fill");

		JTextArea textArea_12 = new JTextArea();
		textArea_12.setName("textArea_12");
		textArea_12.setWrapStyleWord(true);
		textArea_12.setLineWrap(true);
		textArea_12.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_12.setRows(1);
		scrollPane_12.setViewportView(textArea_12);

		JLabel label_13 = new JLabel("14)");
		contentPane.add(label_13, "8, 28");

		JLabel lblWhatDifficultiesExist = new JLabel(
				"What difficulties exist in test maintenance?");
		contentPane.add(lblWhatDifficultiesExist, "10, 28, left, default");

		JComboBox<DesiredEnum> comboBox_13 = new JComboBox<DesiredEnum>(
				DesiredEnum.values());
		comboBox_13.setName("comboBox_13");
		comboBox_13.setMaximumRowCount(DesiredEnum.values().length);
		comboBox_13.setEditable(false);
		comboBox_13.setSelectedItem(DesiredEnum.UNK);
		contentPane.add(comboBox_13, "12, 28, fill, default");

		JScrollPane scrollPane_13 = new JScrollPane();
		contentPane.add(scrollPane_13, "10, 30, 3, 1, fill, fill");

		JTextArea textArea_13 = new JTextArea();
		textArea_13.setName("textArea_13");
		textArea_13.setWrapStyleWord(true);
		textArea_13.setLineWrap(true);
		textArea_13.setFont(new Font("Monospaced", Font.PLAIN, 11));
		textArea_13.setRows(1);
		scrollPane_13.setViewportView(textArea_13);

		JButton btnSave = new JButton("Save");
		btnSave.setActionCommand(ButtonHandler.SAVE);
		btnSave.addActionListener(handler);
		contentPane.add(btnSave, "1, 32, 13, 1");
	}

}
